{%extends 'layout.html'%}
{% block main%}
<ol class="breadcrumb">
    <li><a href="/">管理首页</a></li>
    <li><span href="#">分类列表</span></li>
</ol>
<h3>分类列表</h3>
<table class="table table-hover">
    <tr>
        <th>id</th>
        <th>分类名称</th>
        <th>操作</th>
    </tr>
    {%for categorie in categories%}
    <tr>
        <td>{{categorie._id.toString()}}</td>
        <td>{{categorie.name}}</td>
        <td>
            <a href="/admin/category/edit?id={{categorie._id.toString()}}">修改</a>
            <a href="/admin/category/delete?id={{categorie._id.toString()}}">删除</a>
        </td>
    </tr>
    {%endfor%}
</table>
{%include 'page.html'%}
{%endblock%}